<!-- IF ERROR -->
	<p class="error">{ERROR}</p>
<!-- ENDIF -->

<script>
function sz(t) {
a = t.value.split('\n');
b=1;
for (x=0;x < a.length; x++) {
 if (a[x].length >= t.cols) b+= Math.floor(a[x].length/t.cols);
 }
b+= a.length;
if (b > t.rows) t.rows = b;
}
</script>

<fieldset>
	

	<!-- IF S_PRIVMSGS and not S_SHOW_DRAFTS -->

		<!-- IF S_ALLOW_MASS_PM -->
			<!-- IF .to_recipient -->
				<div class="row">
					<label>{L_TO}:</label>
					<!-- list of recipients (to) -->
					<!-- BEGIN to_recipient -->
							<!-- IF to_recipient.IS_GROUP --><a href="{to_recipient.U_VIEW}"><strong>{to_recipient.NAME}</strong></a>&nbsp;<!-- ELSE -->{to_recipient.NAME_FULL}&nbsp;<!-- ENDIF -->
					<!-- END to_recipient -->
				</div>
			<!-- ENDIF -->
			
			<!-- IF .bcc_recipient -->
				<div class="row">
					<label>{L_BCC}:</label>
					<!-- list of recipients (bcc) -->
					<!-- BEGIN bcc_recipient -->
							<!-- IF not bcc_recipient.S_FIRST_ROW and bcc_recipient.S_ROW_COUNT mod 2 eq 0 --></dd><dd><!-- ENDIF -->
							<!-- IF bcc_recipient.IS_GROUP --><a href="{bcc_recipient.U_VIEW}"><strong>{bcc_recipient.NAME}</strong></a><!-- ELSE -->{bcc_recipient.NAME_FULL}&nbsp;<!-- ENDIF -->
							<!-- IF not S_EDIT_POST --><input type="submit" name="remove_{bcc_recipient.TYPE}[{bcc_recipient.UG_ID}]" value="x" class="button2" />&nbsp;<!-- ENDIF -->
					<!-- END bcc_recipient -->
				</div>
			<!-- ENDIF -->
			
			<!-- IF not S_EDIT_POST -->
			<div class="row">
				<label>{L_TO}:</label>
				<textarea id="username_list" name="username_list" class="inputbox" cols="50" rows="2"></textarea>
			</div>
			<!-- ENDIF -->
			
		<!-- ENDIF -->
	<!-- ENDIF -->


	<!-- IF S_POST_ACTION or S_PRIVMSGS or S_EDIT_DRAFT -->
		<div class="row">
			<label for="subject">{L_SUBJECT}:</label>
			<input type="text" name="subject" id="subject" size="45" maxlength="<!-- IF S_NEW_MESSAGE -->60<!-- ELSE -->64<!-- ENDIF -->" tabindex="2" value="{SUBJECT}{DRAFT_SUBJECT}" class="inputbox autowidth" />
		</div>

		<div class="row" id="message-box">
			<textarea <!-- IF S_UCP_ACTION and not S_PRIVMSGS and not S_EDIT_DRAFT -->name="signature" id="signature" style="height: 9em;"<!-- ELSE -->name="message" id="message"<!-- ENDIF --> rows="4" class="inputbox" onkeyup="sz(this);">{MESSAGE}{DRAFT_MESSAGE}{SIGNATURE}</textarea>
		</div>

		<!-- IF $EXTRA_POSTING_OPTIONS eq 1 -->

			<!-- IF not S_SHOW_DRAFTS and not $SIG_EDIT eq 1 -->
				<div class="row">
					{S_HIDDEN_ADDRESS_FIELD}
					{S_HIDDEN_FIELDS}
					<input type="submit" name="post" value="{L_SUBMIT}" />
				</div>
			<!-- ENDIF -->
		<!-- ENDIF -->

	<!-- ENDIF -->

</fieldset>